package edu.sctu.practice.class02.zengguangchuan.test03;

/**
 * Created by lenovo0 on 2015/10/14.
 */
public class MyTime {
    private int hour;
    private int minute;
    private int second;

    public MyTime(int hour,int minute,int second){
        this.hour=hour;
        this.minute=minute;
        this.second=second;
    }

     void dispay(){
        System.out.println("时间："+hour+"  "+minute+" "+second+" ");
    }

     void addSecond(int sec){
        second=second+sec;
    }

     void addMinute(int min){
        minute=minute+min;
    }

     void addHour(int hou){
        hour=hour+hou;
    }

     void subSecond(int sec){
        second=second-sec;
    }

    void subMinute(int min){
        minute=minute-min;
    }

     void subHour(int hou){
        hour=hour-hou;
    }


}
